<?php
require_once 'PHPUnit/Framework.php';
require_once 'TVB/pms/pdes/common/bootstrap.php';
require_once 'TVB/pms/pdes/common/util/MisApi.class.php'; 
require_once 'TVB/pms/pdes/common/util/MisApiConfig.php'; 

require_once 'TVB/pms/pdes/common/util/mis/MisInfoProduct.class.php';
require_once 'TVB/pms/pdes/common/util/mis/MisMapping.class.php';

class MisInfoProductTest extends PHPUnit_Framework_TestCase
{
    public $info_product;

    function setUp()
    {
        $mis_pdes = array(
            'pdes_eid'  => 83
        );
        $this->info_product = new MisInfoProduct($mis_pdes);
    }

    function tearDown()
    {
        unset($this->info_product);
    }

    function testExistsRelation()
    {
        $products = array(
            '666'
        );
        $ret = $this->info_product->import($products);
		$this->assertEquals($ret, TRUE); 	
    }

    function testNotExistsRelation()
    {
        $products = array(
            '88883'
        );
        $ret = $this->info_product->import($products);
		$this->assertEquals($ret, TRUE); 	
    }
}
?>
